package cn.edu.cug.cs.gtl.renders.openinventor.basics;

import cn.edu.cug.cs.gtl.apis.render.basics.Color;
import com.openinventor.inventor.SbColor;

public class ColorImpl extends Vec3fImpl implements Color {
    public ColorImpl() {
        super(new SbColor());
    }

    public ColorImpl(SbColor v) {
        super(v);
    }

    public ColorImpl(float r, float g, float b){
        super(new SbColor(r,g,b));
    }

    @Override
    public Color clone(){
        SbColor sbColor = new SbColor(
                ((SbColor) this.getNativeObject()).getX(),
                ((SbColor) this.getNativeObject()).getY(),
                ((SbColor) this.getNativeObject()).getZ()
                );
        return new ColorImpl(sbColor);
    }

}
